# Maintainer: Sven-Hendrik Haase <svenstaro@archlinux.org>
# Contributor: Adrian Perez de Castro <aperez@igalia.com>
pkgdesc='Client-side decorations library for Wayland clients'
pkgname=libdecor
pkgver=0.2.0
pkgrel=1
url="https://gitlab.freedesktop.org/libdecor/libdecor"
license=('MIT')
arch=('loong64' 'x86_64')
depends=('wayland' 'pango' 'dbus' 'gtk3')
makedepends=('cmake' 'ninja' 'meson' 'wayland-protocols')
source=("https://gitlab.freedesktop.org/libdecor/libdecor/-/archive/${pkgver}/libdecor-${pkgver}.tar.gz")
sha512sums=('27365c9029caed1064c36490c2007afe5af6ef60c0538a06755be200f122caf444c5dba951fcb954095600469466f75eb75f6f1a642acde065723755a7656a3d')

build() {
  arch-meson -Ddemo=false build "${pkgname}-${pkgver}"
  meson compile -C build
}

package() {
  meson install -C build --destdir "${pkgdir}"
  install -Dm644 "${pkgname}-${pkgver}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
